package spec.ocl_mcg;

import graph.mcg.CGNode;
import graph.mcg.ConstraintNode;

import org.eclipse.ocl.ecore.CallExp;


public class CallExpNode extends TreeNode{
	private String source_node;
	public CallExpNode(CallExp exp){
		source_node = exp.getSource().getName();
	}
	public CallExpNode(){
		
	}
	public String getSource_node() {
		return source_node;
	}

	public void setSource_node(String sourceNode) {
		source_node = sourceNode;
	}

	@Override
	public CGNode toCG() {
		ConstraintNode cfgnode = new ConstraintNode(this);
		
		cfgnode.setConstraint(source_node);
		cfgnode.setNextnode(null);
		return cfgnode;
	}

	@Override
	public String toString() {
		// TODO Auto-generated method stub
		return null;
	}

}
